<?php if (!defined('THINK_PATH')) exit();?><!DOCTYPE html>
<html>

    <head>
        <meta charset="utf-8" />
        <title>首页</title>
        <link rel="stylesheet" href="/Public/Leader/css/bootstrap.css">
        <link rel="stylesheet" type="text/css" href="/Public/Leader/css/index.css" />
        <style type="text/css">
            .order-list a {
                position: relative;
            }

            .order-list span {
                float: right;
                margin-right: 20px;
            }
        </style>
    </head>
    <body>
        
   
<style>
    .pagination .current{
        float: left;
    padding: 0 14px;
    line-height: 38px;
    text-decoration: none; 
    border-left-width: 0;
    }
        
</style>
<div id="topbar" class="top-navigation dark-bg ">
            <nav class="navbar   dark-bg " role="navigation" style="width:85%;margin:auto;">
                <div class="navbar-header" style="width:200px;">
                    <button aria-controls="navbar" aria-expanded="false" data-target="#navbar" data-toggle="collapse" class="navbar-toggle collapsed" type="button">
                        <i class="fa fa-reorder"></i>
                    </button>
                    <a class="navbar-brand" href="<?php echo U('Index/index');?>">小易出行</a>
                </div>
                <div class="navbar-collapse collapse" id="navbar">
                    <ul class="nav navbar-nav dark-bg">
                        

                        <li <?php if($table == 'index'): ?>class="active"<?php endif; ?>>
                            <a href="<?php echo U('Index/index');?>"> 首页</a>
                        </li>

                        <li <?php if($table == 'order'): ?>class="active"<?php endif; ?>>
                            <a href="<?php echo U('Order/orderadmin');?>">订单管理</a>
                        </li>

                        <li <?php if($table == 'pay'): ?>class="active"<?php endif; ?>>
                            <a href="<?php echo U('Pay/paycount');?>">交易中心</a>
                        </li>
                        <li <?php if($table == 'article'): ?>class="active"<?php endif; ?>>
                            <a href="<?php echo U('Article/lst');?>">文章</a>
                        </li>
                        <li <?php if($table == 'wx'): ?>class="active"<?php endif; ?>>
                            <a href="<?php echo U('Wx/wx_menu/wid/1');?>">微信管理</a>
                        </li>
                        <li <?php if($table == 'line'): ?>class="active"<?php endif; ?>>
                            <a href="<?php echo U('Line/lineadmin');?>">线路管理</a>
                        </li>
                        <li <?php if($table == 'user'): ?>class="active"<?php endif; ?>>
                            <a href="<?php echo U('User/userinfo');?>">用户管理</a>
                        </li>
                        <li <?php if($table == 'useradmin'): ?>class="active"<?php endif; ?>>
                            <a href="<?php echo U('Useradmin/userinfo');?>">系统管理</a>
                        </li>

                    </ul>
                    <ul class="nav navbar-top-links navbar-right">
                        <li class="dropdown">
                            <a aria-expanded="false" role="button" href="#" class="dropdown-toggle" data-toggle="dropdown" style="position:relative;" onclick="$(this).find('span').toggleClass('deg180')">
                                <name style="width: 80px;white-space:nowrap;overflow:hidden;text-overflow: ellipsis;display: block;text-align: center"><?php echo session('username');?></name>
                                <span class="caret" style="position: absolute;top: 22px;right: 12px;"></span></a>
                            <ul role="menu" class="dropdown-menu">
                                <li>
                                    <a onclick="return confirm('您确定要退出吗？')" tabindex="-1" href="<?php echo U('Login/Logout');?>">退出</a>
                                </li>
                            </ul>
                        </li>
                    </ul>
                </div>
            </nav>
        </div>
        <div class="wrapper main-wrapper wrapper-content ">
            <div class="page-menubar">
                <ul class="menu-head-top">
                    <li class="active">
                        <a href="<?php echo U('Login/logout');?>&amp;r=order"><img src="/Public/images/ic-1.png" alt="" class="com-icon">首页概述 <i class="fa fa-caret-right"></i></a>
                    </li>
                </ul>
            </div>
            <!--主要内容-->
            <div class="page-content" style="display: block;">
                <!--内容标题-->
                <div class="page-heading">
                    <h2>订单统计</h2>
                </div>
                <!--图标-->
                <div class="row">
                    <!--第一块-->
                    <div class="col-md-6 col-sm-6">
                        <div class="ibox float-e-margins" style="border: 1px solid #e7eaec">
                            <div class="ibox-title">
                                <span class="label label-primary pull-left">历史总成交</span>
                                <span class="pull-right">人均消费 : ¥ <span class="today-avg"><?php echo ($zuihou); ?></span></span>
                                <h5></h5>
                            </div>
                            <div class="ibox-content">
                                <div class="row">
                                    <div class="col-md-6 text-center">
                                        成交量
                                        <h2 class="no-margins today-count"><?php echo ($z_order); ?></h2>
                                    </div>
                                    <div class="col-md-6 text-center">
                                        成交额
                                        <h2 class="no-margins">¥ <span class="today-price"><?php echo ($z_price); ?></span></h2>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
                <div class="row">
                    <!--第一块-->
                    <div class="col-md-6 col-sm-6">
                        <div class="ibox float-e-margins" style="border: 1px solid #e7eaec">
                            <div class="ibox-title">
                                <span class="label label-primary pull-left">今日成交</span>
                                <span class="pull-right">人均消费 : ¥ <span class="today-avg"><?php echo sprintf("%.2f",$price1/$order1);?></span></span>
                                <h5></h5>
                            </div>
                            <div class="ibox-content">
                                <div class="row">
                                    <div class="col-md-6 text-center">
                                        成交量
                                        <h2 class="no-margins today-count"><?php echo ($order1); ?></h2>
                                    </div>
                                    <div class="col-md-6 text-center">
                                        成交额
                                        <h2 class="no-margins">¥ <span class="today-price"><?php echo sprintf("%.2f",$price1);?></span></h2>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                    <!--第二块-->
                    <div class="col-md-6 col-sm-6">
                        <div class="ibox float-e-margins" style="border: 1px solid #e7eaec">
                            <div class="ibox-title">
                                <span class="label label-success pull-left">昨日成交</span>
                                <span class="pull-right">人均消费 : ¥ <span class="yesterday-avg"><?php echo sprintf("%.2f",$price2/$order2);?></span></span>
                                <h5></h5>
                            </div>
                            <div class="ibox-content">
                                <div class="row">
                                    <div class="col-md-6 text-center">
                                        成交量
                                        <h2 class="no-margins yesterday-count"><?php echo ($order2); ?></h2>
                                    </div>
                                    <div class="col-md-6 text-center">
                                        成交额
                                        <h2 class="no-margins">¥ <span class="yesterday-price"><?php echo ($price2); ?></span></h2>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                    <!--第三块-->
                    <div class="col-md-6 col-sm-6">
                        <div class="ibox float-e-margins" style="border: 1px solid #e7eaec">
                            <div class="ibox-title">
                                <span class="label label-warning pull-left">本周成交</span>
                                <span class="pull-right">人均消费 : ¥ <span class="seven-avg"><?php echo sprintf("%.2f",$price3/$order3);?></span></span>
                                <h5></h5>
                            </div>
                            <div class="ibox-content">
                                <div class="row">
                                    <div class="col-md-6 text-center">
                                        成交量
                                        <h2 class="no-margins seven-count"><?php echo ($order3); ?></h2>
                                    </div>
                                    <div class="col-md-6 text-center">
                                        成交额
                                        <h2 class="no-margins">¥ <span class="seven-price"><?php echo sprintf("%.2f",$price3);?></span></h2>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                    <!--第四块-->
                    <div class="col-md-6 col-sm-6">
                        <div class="ibox float-e-margins" style="border: 1px solid #e7eaec">
                            <div class="ibox-title">
                                <span class="label label-danger pull-left">本月成交</span>
                                <span class="pull-right">人均消费 : ¥ <span class="month-avg"><?php echo sprintf("%.2f",$price4/$order4);?></span></span>
                                <h5></h5>
                            </div>
                            <div class="ibox-content">

                                <div class="row">
                                    <div class="col-md-6 text-center">
                                        成交量
                                        <h2 class="no-margins month-count"><?php echo ($order4); ?></h2>
                                    </div>
                                    <div class="col-md-6 text-center">
                                        成交额
                                        <h2 class="no-margins">¥ <span class="month-price"><?php echo ($price4); ?></span></h2>
                                    </div>
                                </div>

                            </div>
                        </div>
                    </div>
                    <div class="col-sm-12">
                        <div class="ibox float-e-margins" style="border: 1px solid #e7eaec">
                            <div class="ibox-title">
                                <h5>交易走势图</h5>
                            </div>
                            <div class="ibox-content" style="height: 400px;">
                                <div id="main" class="col-md-12 col-sm-12 col-xs-12" style="height:350px;"></div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </body>
    <script>
        var datas = <?php echo ($tongji2['riqi']); ?>;
        var prices = <?php echo ($tongji2['price']); ?>;
        var orders = <?php echo ($tongji2['order']); ?>;
    </script>
    <script src="/Public/Leader/js/jquery.js" type="text/javascript" charset="utf-8"></script>
    <script src="/Public/Leader/js/bootstrap.min.js" type="text/javascript" charset="utf-8"></script>
    <script src="/Public/Leader/js/echarts.js" type="text/javascript" charset="utf-8"></script>
    <script src="/Public/Leader/js/tubiao.js" type="text/javascript" charset="utf-8"></script>

</html>